import Request from '@/components/pocky-request/index.js'

const apiUrl = {
	login: '/common/userLogin',
	regist: '/common/userRegister',
	loginCode: '/common/get_userRegisterverify_code'
}

/**
 * 获取分类
 * @param {Object} parameter
 */
export function doLogin(data) {
	return Request().request({
	  url: apiUrl.login,
	  method: 'POST',
	  data: data
	})
}

/**
 * 获取分类
 * @param {Object} parameter
 */
export function doRegist(data) {
	return Request().request({
	  url: apiUrl.regist,
	  method: 'POST',
	  data: data
	})
}

/**
 * 获取分类
 * @param {Object} parameter
 */
export function getLoginCode(data) {
	return Request().request({
	  url: apiUrl.loginCode,
	  method: 'POST',
	  data: data
	})
}